
<?php

use Illuminate\Routing\Router;
use Illuminate\Support\Facades\Route;
use Dcat\Admin\Admin;

use App\Http\Controllers\Api\Agent\CreateShortUrlController;

Admin::routes();

Route::group([
    'prefix'     => config('agent-admin.route.prefix'),
    'namespace'  => config('agent-admin.route.namespace'),
    'middleware' => config('agent-admin.route.middleware'),
], function (Router $router) {

    $router->get('/', 'HomeController@index');
    $router->resource('videos', 'Videos\VideoController');
    $router->resource('short-urls', 'ShortUrlController');//短网址
    $router->any('/create-short-url',[CreateShortUrlController::class, 'store']);

    $router->resource('agent-price', 'AgentPriceController');
    $router->resource('agent-orders', 'OrderController');


    $router->resource('account-details', 'AgentAccountDetailController');
    $router->resource('agent-accounts', 'AgentAccountController');
    $router->resource('withdraws', 'WithdrawController');


    $router->resource('out-video', 'Videos\OutVideoController');

});